package Data;
//SimpleDataFormat

import javax.xml.crypto.Data;
import java.sql.SQLOutput;
import java.sql.Time;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.SimpleTimeZone;

public class Demo2 {
    public static void main(String[] args) {
        /*字符串----->日期
        * */
        SimpleDateFormat time = new SimpleDateFormat("yyyy-MM-dd");
        String format = time.format(new Date());
        System.out.println(format);

        /*日期----->字符串
         * */
        String str = "2019-08-09";
//        new Simple
    }
}
